home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Aminet 24
/
Aminet 24 (1998)(GTI - Schatztruhe)[!][Apr 1998].iso
/
Aminet
/
biz
/
demo
/
Electrics_demo.lha
/
AShell.rexx
< prev
next >
Wrap
OS/2 REXX Batch file
|
1996-02-28
|
822b
|
52 lines
/*------------------------------*/
/* Electrics ARexx Shell script */
/*------------------------------*/
OPTIONS PROMPT "2;>0m>>m"
OPTIONS RESULTS
RC = 0
say "Enter 'HELP' for help."
say ""
error:
SIGNAL ON error
if RC ~= 0 THEN DO
SAY "+++ ERROR: RC = " RC
RC = 0
END
syntax:
SIGNAL ON syntax
if RC ~= 0 THEN DO
SAY "+++ SYNTAX ERROR:" ERRORTEXT(RC)
RC = 0
END
DO FOREVER
PARSE PULL shell_line
if UPPER(shell_line) == 'QUIT' THEN DO
address COMMAND endcli
EXIT
END
else if UPPER(shell_line) == 'HELP' THEN DO
say ""
say "QUIT: Exit the ARexx Shell."
say "HELP: Displays this help."
say ""
end
else do
interpret shell_line
if RESULT ~= 'RESULT' THEN DO
say RESULT
RESULT = 'RESULT'
END
END
END